package br.uff.busuffweb.model;

import java.io.Serializable;
import javax.persistence.Entity;
import javax.persistence.NamedQueries;
import javax.persistence.NamedQuery;
import javax.persistence.PrimaryKeyJoinColumn;
import javax.persistence.Table;

/**
 *
 * @author jthiago
 */
@NamedQueries({
    @NamedQuery(name = "Parada.getTodas",
    query = "select p from Parada p order by p.id"),
    
    @NamedQuery(name = "Onibus.getPorNome",
    query = "select p from Parada p " +
            " where p.nome = ?")
})
@Entity
@PrimaryKeyJoinColumn(name = "idPonto")
@Table(name = "parada")
public class Parada extends Ponto implements Serializable {

    private String nome;
    
    private String descricao;

    public String getNome() {
        return nome;
    }

    public void setNome(String nome) {
        this.nome = nome;
    }

    public String getDescricao() {
        return descricao;
    }

    public void setDescricao(String descricao) {
        this.descricao = descricao;
    }
}
